double sum(int x, int n) {    
    if (x > n)    
        return 0.0;    
    if (x == n)    
        return 1.0 / x;    
    double temp =  1.0 / x;    
    if (x > 0)    
        x++;    
    else    
        x--;    
    return sum(x, n) + temp;    
}    
    
int main() {    
    double ans;    
    int n;    
    if (scanf("%d", &n));    
        printf("sum=%.6f\n", 1.0 + sum(2, n));    
    return 0;    
}  